const promise = new Promise((resolve, reject) => {
  reject('failure');
});

promise
  .then((result) => {
    console.log(result);
  })
  .catch((error) => {
    console.log(error);
  });
promise.catch((error) => {
  console.log(error);
});
promise.catch((error) => {
  console.log(error);
});
promise.catch((error) => {
  console.log(error);
});
